package com.zksk.portal.controller.consult;

import com.zksk.admin.api.domain.portal.vo.ConsultVo;
import com.zksk.common.core.domain.R;
import com.zksk.common.core.web.controller.BaseController;
import com.zksk.common.log.annotation.Log;
import com.zksk.common.log.enums.BusinessType;
import com.zksk.portal.service.consult.ConsultService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.apache.ibatis.annotations.Insert;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;



@Slf4j
@RequestMapping("/consult/")
@RestController
@Api(tags = "企业咨询相关接口")
public class ConsultController extends BaseController
{

    @Autowired
    private ConsultService consultService;



    @PostMapping("insert")
    @Log(title = "新增企业咨询", businessType = BusinessType.INSERT)
    @ApiOperation(value = "新增企业咨询信息")
    public R insert(@RequestBody @Validated(Insert.class)ConsultVo consultVo)
    {
        return consultService.insert(consultVo);
    }

}
